The stock average calculator finds the weighted average purchase price across as many as five buys. A simple average of quoted prices is misleading when the quantities differ; buying 100 shares at one price should influence the result more than buying 10 shares at another. This page multiplies each valid quantity by its price, adds those purchase amounts, then divides by total shares. It also shows total stock cost and total shares. Commissions, taxes, dividends, sales, splits, and currency conversion are outside this calculation.
Stock Average Calculator
Form
Results
Stock cost
0
Table of Contents
What is Stock Average?
How to Use This Calculator
- Enter the first share quantity and price; both are required and must be positive.
- Select one currency for every price. Later rows use that same currency.
- Add up to four more purchases. For each row you use, enter both quantity and price. Leave both boxes empty when a row is unused.
- Choose Calculate to see total purchase cost, total shares, and weighted average price per share.
Enter quantities exactly as held, including permitted fractional shares. Prices should be the execution prices from the same type of record and the same currency. If commissions need to be included in a personal tracking estimate, first allocate them to the relevant purchase cost outside this page; do not silently add a fee to the price unless you document that choice.
Formula Used
For each purchase:
purchase amount = shares bought × price per share
Across all entered purchases:
total shares = sum of shares in every purchase
total purchase cost = sum of all purchase amounts
weighted average purchase price = total purchase cost ÷ total shares
This is a quantity-weighted average. It is different from adding the five quoted prices and dividing by five. The calculation includes only completed rows containing both a positive quantity and positive price.
Variables Explained
| Value | Meaning |
|---|---|
| Buy quantity | Shares acquired in one transaction; each used row must be greater than zero. |
| Buy price | Execution price per share for that transaction. |
| Currency | Common unit for all prices; PKR, USD, EUR, and CAD are available labels. |
| Purchase amount | Quantity multiplied by price for one row. |
| Total stock cost | Sum of entered purchase amounts before unentered fees and taxes. |
| Total shares | Sum of all entered quantities. |
| Average price | Total stock cost divided by total shares. |
Worked Example
Suppose the first buy is 10 shares at $20 and the second is 30 shares at $25. The purchase amounts are 10 × $20 = $200 and 30 × $25 = $750. Total cost is $950 and total shares are 40. Weighted average price is $950 ÷ 40 = $23.75 per share. A plain average of $20 and $25 would be $22.50, which is wrong for these holdings because three times as many shares were bought at $25.
Why Use This Calculator?
The average price is a compact description of the entered purchases. A current market price above that average suggests an unrealized gain before fees and taxes; a lower market price suggests an unrealized loss. The displayed total stock cost does not include brokerage commission, regulatory charges, or currency effects, so it may differ from a broker’s cost basis.
Do not assume this arithmetic average is automatically the tax basis for shares you sell. In the United States, average basis is generally limited to eligible mutual-fund or dividend-reinvestment-plan shares, while individual stock lots commonly use specific identification or a default ordering method. Corporate actions and wash-sale adjustments can also alter records. Use brokerage statements and official tax guidance for reporting, and consult a qualified adviser when the correct lot treatment is uncertain.
Common Mistakes
- Taking a simple mean of the purchase prices ignores how many shares were bought in each transaction.
- Entering a quantity without its matching price leaves an incomplete purchase and should be corrected.
- Mixing USD, CAD, EUR, or PKR without converting them first makes the total invalid.
- Assuming the output includes commissions when only quantity and price were entered understates cost.
- Entering sale transactions as negative buys does not model realized gains correctly and is not accepted.
- Using rounded totals from memory instead of execution records can create avoidable differences.
- Treating weighted average purchase price as the permitted tax method for every security may produce incorrect reporting.
Frequently Asked Questions
Why is this a weighted average?
Each price is weighted by the shares bought at that price. This makes the result describe the combined holding instead of giving a small purchase the same influence as a large one.
Can I enter only two purchases?
Yes. Complete the required first row and any additional full rows you need. Leave both quantity and price empty for unused rows.
Does the total include brokerage fees?
No. It sums quantity times price for each entered purchase. Commissions, regulatory fees, taxes, and currency conversion are not separate inputs here.
Can I mix different currencies?
No. Convert all prices to one currency at appropriate transaction exchange rates before calculating. The selected currency is a label and does not perform foreign-exchange conversion.
Can I add a sale as a negative quantity?
No. The page accepts positive purchase quantities. Sales require lot tracking and realized-gain treatment that a purchase-only weighted average does not provide.
Is this average my tax cost basis?
Not necessarily. Fees, adjustments, corporate actions, and permitted lot-selection methods affect tax basis. Average basis is not allowed for every kind of security or jurisdiction.
How do fractional shares affect the result?
They work like whole shares in the weighted formula. Enter the exact positive quantity and matching execution price shown in your transaction record.
Sources & References
The IRS stock-basis FAQ describes identification rules and the limited situations in which average basis may be used. IRS Publication 550 provides more detail on investment income and basis. The SEC’s Investor.gov guide to brokerage statements explains why transaction and cost-basis records deserve review. Use the authority for your own country when filing taxes.
